//
//  TenderFollowTagCell.swift
//  ZYA
//
//  Created by 邱仙凯 on 2020/10/21.
//  Copyright © 2020 zwb. All rights reserved.
//

import UIKit

class TenderFollowTagCell: UITableViewCell {
    
    
    private var btn1: StatusButton!
    private var lab1: UILabel!
    
   
    private var titleAttributes:[NSAttributedString.Key : NSObject]!
    private var lab3Attributes:[NSAttributedString.Key : NSObject]!
    private let helper = ZyaTenderHelper()
    
    override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
        super.init(style: style, reuseIdentifier: reuseIdentifier)
        
        btn1 = StatusButton()
        addSubview(btn1)
        lab1 = UILabel()
        addSubview(lab1)
        
        btn1.snp.makeConstraints { (make) in
            make.left.equalTo(self.contentView).offset(10)
            make.width.equalTo(60)
            make.height.equalTo(25)
            make.top.equalTo(self.contentView).offset(10)
            make.bottom.equalTo(self.contentView).offset(-10)
        }
        lab1.snp.makeConstraints { (make) in
            make.left.equalTo(btn1.snp.right).offset(11)
            make.centerY.equalTo(btn1)
        }
      
        
    }
 
    
    
    
    required init?(coder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    var one = ZtbContentModel(JSON:["":""])! {
        didSet {
             
            lab1.text = one.providerNm
            btn1.setTitle(one.tag.unwrap == "1" ? "已投标" : "未投标", for: .normal)
            
            
        }
    }
   
    
    
    override func setSelected(_ selected: Bool, animated: Bool) {
        super.setSelected(selected, animated: animated)
        
        // Configure the view for the selected state
    }
    
}
